// pages/index/index.js
const requestInstance = require('@/utils/http/request')
Page({

  /**
     * 页面的初始数据
     */

  data: {
    titleIcon: 'index - header titleIcon',
    list: [
      { name: 'a1' },
      { name: 'a2' }
    ],
    obj: {
      name: 'test',
      age: 18
    },
    inputVal: '123'

  },
  computed: {
    inputValB() {
      return this.data.inputVal + '4'
    }
  },
  watch: {
    'inputValB'(v, ov) {
      console.log(v, ov)
    }
  },
  test() {
    requestInstance({
      url: 'https://www.baidu.com/s?ie=utf-8&wd=%E9%BA%A6%E7%94%B0',
      isLoading: true
    }).then(res => {
      console.log(res)
    })
    // wx.navigateTo({
    //   url: '/pages/user/user'
    // })
  }

})
